#!/bin/bash
filenames=$(ls ./temp)
number=1
for name in $filenames
do
        printf "命令前:%s" ${name}
        newname=${name}"-"${number}
        rename $name ${newname} ./temp/*
        let number++ 
        printf "重命名后:%s \n" ${newname}
done
